package com.resign.carl.decorate.api.impl;

import com.resign.carl.decorate.api.Beverage;
import com.resign.carl.decorate.api.CondimentDecorator;

/**
 * Created by carl.zhao on 2016/6/14.
 */
public class Whip extends CondimentDecorator {
    private Beverage beverage;
    public Whip(Beverage beverage){
        this.beverage = beverage;
    }
    @Override
    public String getDescription() {
        return beverage.getDescription() + ", Whip";
    }

    @Override
    public double cost() {
        return 1.98D + beverage.cost();
    }
}
